﻿/**
 * Peter
 * Created by: Peter Development Team
 *    http://peter.codeplex.com/
 * 
 * GNU General Public License version 2 (GPLv2)
 *    http://peter.codeplex.com/license
 *
 *  This code is provided on an AS IS basis, with no WARRANTIES,
 *  CONDITIONS or GUARANTEES of any kind.
 *
 **/

using Microsoft.VisualStudio.TestTools.UnitTesting;
using Peter.Ftp.Logic;
using Peter.Ftp.View;

namespace Peter.Ftp.Tests.View
{
   /// <summary>
   /// Test cases for the ftp views.
   /// </summary>
   [TestClass]
   public class TestViews
   {
      /// <summary>
      /// Tests the ftp view.
      /// </summary>
      [TestMethod]
      public void TestViewFtp ()
      {
         var view = new ViewFtp ();
         Assert.IsNotNull (view);
      }

      /// <summary>
      /// Test the ftp options view.
      /// </summary>
      [TestMethod]
      public void TestViewFtpOptions ()
      {
         var view = new ViewFtpOptions ();
         Assert.IsNotNull (view);
         var options = new OptionsFtp ();
         view.DataContext = options;
         options.AddConnection.Execute (null);
         options.AddConnection.Execute (null);
         options.SelectedConnection.Password = "TestPassword";
      }
   }
}
